<?php
$people = array("Peter", "Joe", "Glenn", "Cleveland");
if (in_array("Glenn",$people))//在数组中搜索给定的值在数组中搜索给定的值
  {
  echo "Match found";//搜索成功
  }
else
  {
  echo "Match not found";//搜索失败
  }
?>